<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="initial-scale=1,maximum-scale=1,user-scalable=no,width=device-width">
    <meta name="format-detection" content="telephone=yes"/>
    <meta name="description" content="产品信息！！！" />
    <title>哈啰通用</title>
    <link rel="stylesheet" href="css/reset.css">
    <link rel="stylesheet" href="css/base.css">
    <link rel="stylesheet" href="css/product.css">
    <style>
.product-iframe{position: absolute;top: 0;width: 100%;}
    </style>
</head>
<body>
<div class="wrapper">
    <div class="product-inf">
    </div>
    <!--<footer class="footer-cart b-top">-->
        <!--<div class="foot-div dis_in">-->
            <!--<div class="foot-add">-->
                <!--<img class="jian" src="../images/Artboard%2031@3x.png" alt="">-->
                <!--<input type="text" value="1" id="input-num1">-->
                <!--<img  class="add" src="../images/Artboard%2032@3x.png" alt="">-->
            <!--</div>-->

        <!--</div>-->
        <!--<div class="f-btn11 dis_in">-->
            <!--<button class="btn" onclick="hahah()">加入购物车</button>-->
        <!--</div>-->
    <!--</footer>-->

</div>
<script src="js/jquery-1.8.3.min.js"></script>
<script src="js/base.js"></script>
<script src="js/base64.js"></script>
<script>

    $(document).ready(function() {
        localStorage.getItem("key");//获取存储的变量key的值
        localStorage.key;//获取存储的变量key的值
        var code= localStorage.getItem("key");
        console.log( code);
        var ID;
        var falg;
        var URL='http://localhost/rest/';
        if(code==='HA01-PRS250AD'|| code==='HA01-SIG145AD'|| code==='HA01-SIG210AD'|| code==='HA01-SIG250AD' || code==='HA01-PRS145VSAD'||code==='HA01-PRS250VSAD'||  code==='HA01-PRS210AD' ||code==='HA01-PRS210VSAD'|| code==='HA01-PRS145AD'){
            ID='8231e438955998475b1734dcfb5a38f2';
            falg=1;

        } else if(code==='HA01-PRS185AD' ||code==='HA01-PRS185VSAD' ||code==='HA01-SIG185AD'){
            ID='4ccb64bff7978a39b4fb4faccfee3590';
            falg=1;
        }else      if(code==='HA01-Singa250LEDVSAD'||code==='HA01-Singa210LEDVSAD'){
            ID='290f8ec8d31f96c8d5006d2e3f1c6bec';
            falg=1;
        }else     if(code==='HA01-Singa185LEDVSAD'){
            ID='f1987389c3f7f1b7b8bce3b1bd9eb5b0';
            falg=1;
        }else    if(code==='HH01--KK50-111-CH-HU'){
            ID='59e80eaaa8bb177f432475ea1dc742c7';
            falg=1
        }else  if(code==='HH01--KK50-112-CH-HU'){
            ID='6563a3f63ced72e2cb400bf49ca075c3';
            falg=1
        }else  if(code==='HH01--KK50-113-CH-HU'){
            ID='d50cb549d3adcd014a1ee2d018cb6d57';
            falg=1
        }else  if(code==='HH01--KK50-114-CH-HU'){
            ID='e1611a5109c5154762364f8b2109f0bf';
            falg=1
        }else  if(code==='HH01--KK50-115-CH-HU'){
            ID='4910660e105af94d5c51e4d090b5bb2b';
            falg=1
        }else  if(code==='HH01--KK50-116-CH-HU'){
            ID='4f6cf61f4501c999e6b65344e769f87e';
            falg=1
        }else   if(code==='HH01--KK50-117-CH-HU'){
            ID='d34043e913073a976b9b29d196966c3b';
            falg=1
        }else     if(code==='HH01-KK50-118-CH-HU'){
            ID='3ce96f47ab1c8c34c2fc97d8e7431f2a';
            falg=1
        }else   if(code==='HH01-KK50-119-CH-HU'){
            ID='b96d8c2c36f46b8f577372b5094dae80';
            falg=1
        }else   if(code==='HH01-KK50-120-CH-HU'){
            ID='2b39ece5c1ed23e2ac4d25154671648b';
            falg=1
        }else   if(code==='HH01-KK50-121-CH-HU'){
            ID='0858a3106f9d614661af34990370a637';
            falg=1
        }else {
            falg=2;

        }
        jQuery.ajax({
                url:'/rest/ProjectInfoPanel_Level_Detail_Grid1?Inventorylistviewcinvcode='+code+'&start=0&count=15&gxid=2',
                type: "GET",
                data:'id',
                dataType: "json",
                success: function (data) {
                    var comHtml = '';
                    if(null!=data) {
                        var  dataArr = data[0];
                        var Code = dataArr.InventoryListViewcInvCode;
                        var Name = dataArr.InventoryListViewcInvName;
                        var Std = dataArr.InventoryListViewcInvStd;
                        var Define1 = dataArr.InventoryListViewcInvDefine1;
                        var Define2 = dataArr.InventoryListViewcInvDefine2;
                        var Define3 = dataArr.InventoryListViewcInvDefine3;
                        var Define4 = dataArr.InventoryListViewcInvDefine4;
                        var Define5 = dataArr.InventoryListViewcInvDefine5;
                        var Define6 = dataArr.InventoryListViewcInvDefine6;
                        var Define7 = dataArr.InventoryListViewcInvDefine7;
                        var Define8 = dataArr.InventoryListViewcInvDefine8;
                        var Define9 = dataArr.InventoryListViewcInvDefine9;
                        var Price = dataArr.InventoryListViewfRetailPrice;
                        var Vpicture = dataArr.Vpicture;

                        comHtml = '<div class="product-inf">' +
                            '<div class="product-top-pic" id="pro-t-pic">' +
                            '</div>' +
                            '<div class="product-inf-list">' +
                            '<ul>' +
                            '<li >' +
                            '<span class="f50 sp">商品编号</span><span id="test" class="pro-inf-li-sp">' + Code + '</span>' +
                            '</li>' +
                            '<li class="pro-li">' +
                            '<span class="f50 sp">商品名称</span><span class="pro-inf-li-sp">' + Name + '</span>' +
                            '</li>' +
                            '<li>' +
                            '<span class="f50 sp">型号</span><span class="pro-inf-li-sp">' + Std + '</span>' +
                            '</li>' +
                            '<li class="pro-li">' +
                            '<span class="f50 sp">外尺寸（mm）</span><span class="pro-inf-li-sp">' + Define1 + '</span>' +
                            '</li>' +
                            '<li>' +
                            '<span class="f50 sp">内尺寸（mm）</span><span class="pro-inf-li-sp">' + Define2 + '</span>' +
                            '</li>' +
                            '<li class="pro-li">' +
                            '<span class="f50 sp">毛容量/经容量（L）</span><span class="pro-inf-li-sp fr">' + Define3 + '</span>' +
                            '</li>' +
                            '<li>' +
                            '<span class="f50 sp">温度范围</span><span class="pro-inf-li-sp">' + Define4 + '<span style="display:inline-block;width: 10px;"></span></span>' +
                            '</li>' +
                            '<li class="pro-li">' +
                            '<span class="f50 sp">制冷剂类型</span><span class="pro-inf-li-sp">' + Define5 + '</span>' +
                            '</li>' +
                            '<li>' +
                            '<span class="f50 sp">电压、频率</span><span class="pro-inf-li-sp">' + Define6 + '</span>' +
                            '</li>' +
                            '<li class="pro-li">' +
                            '<span class="f50 sp">额定功率（W）</span><span class="pro-inf-li-sp">' + Define7 + '</span>' +
                            '</li>' +
                            '<li>' +
                            '<span class="f50 sp">能耗（25℃）</span><span class="pro-inf-li-sp">' + Define8 + '</span>' +
                            '</li>' +
                            '<li class="pro-li">' +
                            '<span class="f50 sp">毛重/净重（kg）</span><span class="pro-inf-li-sp">' + Define9 + '</span>' +
                            '</li>' +
                            '<li>' +
                            '<span class="f50 sp">零售价</span><span class="pro-sp1 f-red pro-wid">' + Price + '</span>' +
                            '</li>' +
                            '</ul>' +
                            '</div>' +
                            '</div>'

                    }

                    $('.product-inf').html(comHtml);
                     if(falg==1){
                        var $iframDiv=$('<Iframe id="myIframe" src="http://www.othkin.com/3DExp/ShowH5.html?id='+ID+'" width="100%" height="198px" scrolling="[OPTION]" frameborder="0" name="main"></iframe>');
                        var $product=$('.product-top-pic');
                        $product.append($iframDiv);
                    }else if(falg==2){
                        $('.product-top-pic').html('<img src="http://app.besenz.cn:9778/' + Vpicture + '" onerror="onerror=null;src=\'../../images/Artboard 77 Copy.png\'" alt="">');
                    }
                }
    });

    });

</script>
</body>
</html>